export const enum ChannelType {
  PHONE = 1,
  CHAT
}

export const enum CommlibEventType {
  CHANGE = 1,
  NEW
}

export const enum CommlibErrorType {
  INITIAL_FAILED = 10001
}

export const enum DeviceErrorType {
  STATE_CHANGE_FAILED = 20001,
  MUTE_FAILED,
  HOLD_FAILED,
  UNHOLD_FAILED,
  HANGUP_FAILED,
  UNREGISTER_FAILED,
  REGISTER_FAILED,
  RECONNECTED_FAILED,
  ERROR
}

export const enum ContactErrorType {
  SEND_MSG_FAILED = 30001,
  TYPING_FAILED,
  JOIN_CONTACT_FAILED,
  HANGUP_FAILED,
  CONNECT_FAILED,
  INVALID_MSG,
  LOAD_MSGS_FAILED,
  HOLD_FAILED,
  RESUME_FAILED
}

export const enum DeviceEventType {
  CONNECTED = 1,
  RECONNECTED,
  CHANGE
}

export const enum ContactEventType {
  NEW = 10001,
  NEW_MESSAGE,
  MESSAGE_MODIFIED,
  MESSAGE_REMOVED,
  MESSAGES_MORE,
  TYPING,
  USER_JOINED,
  USER_LEFT,
  CONNECTED,
  DISCONNECTED,
  CHANGE,
  MESSAGES_LOADED
}

export const enum DeviceState {
  CONNECTING = 1,
  CONNECTED,
  OFFLINE,
  DISCONNECTED,
  NOTROUTABLE,
  ROUTABLE
}

export const enum ContactState {
  INCOMING = 10001,
  ACCEPTED,
  CONNECTED,
  CONNECTING,
  HOLD,
  MUTE,
  HOLDANDMUTE,
  // DISCONNECTED,
  // REJECTED,
  ENDED,
  UNKNOWN
}

export const enum DirectionType {
  INBOUND = 1,
  OUTBOUND,
  OTHERS
}

export const enum MessageFormat {
  STRING = 1,
  LINK,
  AUDIO,
  VIDEO,
  HTML,
  XML
}

export const enum MessageType {
  MESSAGE = 1,
  ADMIN,
  FILE,
  EMAIL,
  INTRO,
  NOTE,
  SERVICE_CALL,
  DECISION,
  SYSTEM
}

export const enum ProviderType {
  PREDEFINED = 1,
  DYMAMICLOAD
}

export const enum UserState {
  UNKNOWN = 1,
  AVAILABLE,
  UNAVAILABLE,
  BUSY
}
